package com.sskj.one.proxy;


import com.sskj.common.base.HttpData;
import com.sskj.lib.http.JsonCallBack;
import com.sskj.one.bean.TeamLevelBean;
import com.sskj.one.presenter.BasePresenter;

/**
 * @author Hey
 * Create at  2019/05/22
 */
class TeamLevelPresenter extends BasePresenter<TeamLevelActivity> {

    public void getTeamLevelInfo(boolean showLoading) {
        httpService.getTeamLevelInfo()
                .tag(this)
                .execute(new JsonCallBack<HttpData<TeamLevelBean>>(showLoading?this:null) {
                    @Override
                    public void onHTTPSuccess(HttpData<TeamLevelBean> data) {
                        mView.getTeamLevelInfoOK(data.getData());
                    }

                    @Override
                    public void onFinish() {
                        super.onFinish();
                        mView.stopRefresh();
                    }
                });
    }
}
